package p2psim.queue;

import java.util.ArrayList;
import java.util.List;

import p2psim.event.Event;

public class EventList {

	private List<Event> list;

	public EventList() {
		init();
	}

	private void init() {
		list = new ArrayList<Event>();
	}

	public void handleEvents() {
		for (Event e : list) {
			e.execute();
		}
	}

	public void addEvent(Event e) {
		list.add(e);
	}
}
